<!DOCTYPE HTML>
<html lang="zh-CN">


<head><meta name="generator" content="Hexo 3.8.0">
    <meta charset="utf-8">
    <meta name="keywords" content="AndroidStudio常用快捷键, 508工作室">
    <meta name="description" content="常用的 Android Studio 快捷键:以下是平时在Windwos系统上用Android Studio进行开发时常用到的一些快捷键，虽然不多，但是感觉都还蛮实用的，因此记录下来，如果什么时候不小心忘记了可以拿来翻一翻，That wou">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
    <meta name="renderer" content="webkit|ie-stand|ie-comp">
    <meta name="mobile-web-app-capable" content="yes">
    <meta name="format-detection" content="telephone=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
    <title>AndroidStudio常用快捷键 | 508工作室</title>
    <link rel="icon" type="image/png" href="/favicon.png">

    <link rel="stylesheet" type="text/css" href="/libs/awesome/css/all.css">
    <link rel="stylesheet" type="text/css" href="/libs/materialize/materialize.min.css">
    <link rel="stylesheet" type="text/css" href="/libs/aos/aos.css">
    <link rel="stylesheet" type="text/css" href="/libs/animate/animate.min.css">
    <link rel="stylesheet" type="text/css" href="/libs/lightGallery/css/lightgallery.min.css">
    <link rel="stylesheet" type="text/css" href="/css/matery.css">
    <link rel="stylesheet" type="text/css" href="/css/my.css">
    <script src="/js/quicklink.umd.js"></script>
    <script>
        window.addEventListener('load', () => {
            quicklink.listen();
        });
    </script>
    <script src="/libs/jquery/jquery.min.js"></script>

<link rel="stylesheet" href="/css/prism-tomorrow.css" type="text/css"></head>


<body>
    <header class="navbar-fixed">
    <nav id="headNav" class="bg-color nav-transparent">
        <div id="navContainer" class="nav-wrapper head-container">
            <div class="brand-logo">
                <a href="/" class="waves-effect waves-light">
                    
                    <img src="/medias/logo.png" class="logo-img" alt="LOGO">
                    
                    <span class="logo-span">508工作室</span>
                </a>
            </div>
            

<a href="#" data-target="mobile-nav" class="sidenav-trigger button-collapse"><i class="fas fa-bars"></i></a>
<ul class="right nav-menu">
  
  <li class="hide-on-med-and-down nav-item">
    
    <a href="/" class="waves-effect waves-light">
      
      <i class="fas fa-home" style="zoom: 0.6;"></i>
      
      <span>首页</span>
    </a>
    
  </li>
  
  <li class="hide-on-med-and-down nav-item">
    
    <a href="/tags" class="waves-effect waves-light">
      
      <i class="fas fa-tags" style="zoom: 0.6;"></i>
      
      <span>标签</span>
    </a>
    
  </li>
  
  <li class="hide-on-med-and-down nav-item">
    
    <a href="/categories" class="waves-effect waves-light">
      
      <i class="fas fa-bookmark" style="zoom: 0.6;"></i>
      
      <span>分类</span>
    </a>
    
  </li>
  
  <li class="hide-on-med-and-down nav-item">
    
    <a href="/archives" class="waves-effect waves-light">
      
      <i class="fas fa-archive" style="zoom: 0.6;"></i>
      
      <span>归档</span>
    </a>
    
  </li>
  
  <li class="hide-on-med-and-down nav-item">
    
    <a href class="waves-effect waves-light">

      
      <i class="fas fa-list" style="zoom: 0.6;"></i>
      
      <span>关于</span>
      <i class="fas fa-chevron-down" aria-hidden="true" style="zoom: 0.6;"></i>
    </a>
    <ul class="sub-nav menus_item_child ">
      
      <li>
        <a href="/about">
          
          <i class="fas fa-user-circle" style="margin-top: -20px; zoom: 0.6;"></i>
          
          <span>简介</span>
        </a>
      </li>
      
      <li>
        <a href="/team">
          
          <i class="fas fa-user-circle" style="margin-top: -20px; zoom: 0.6;"></i>
          
          <span>团队</span>
        </a>
      </li>
      
    </ul>
    
  </li>
  
  <li class="hide-on-med-and-down nav-item">
    
    <a href="/friends" class="waves-effect waves-light">
      
      <i class="fas fa-address-book" style="zoom: 0.6;"></i>
      
      <span>友情链接</span>
    </a>
    
  </li>
  
  <li>
    <a href="#searchModal" class="modal-trigger waves-effect waves-light">
      <i id="searchIcon" class="fas fa-search" title="搜索" style="zoom: 0.85;"></i>
    </a>
  </li>
</ul>

<div id="mobile-nav" class="side-nav sidenav">

    <div class="mobile-head bg-color">
        
        <img src="/medias/logo.png" class="logo-img circle responsive-img">
        
        <div class="logo-name">508工作室</div>
        <div class="logo-desc">
            
            晋城职业技术学院508工作室独立站点
            
        </div>
    </div>

    

    <ul class="menu-list mobile-menu-list">
        
        <li class="m-nav-item">
	  
		<a href="/" class="waves-effect waves-light">
			
			    <i class="fa-fw fas fa-home"></i>
			
			首页
		</a>
          
        </li>
        
        <li class="m-nav-item">
	  
		<a href="/tags" class="waves-effect waves-light">
			
			    <i class="fa-fw fas fa-tags"></i>
			
			标签
		</a>
          
        </li>
        
        <li class="m-nav-item">
	  
		<a href="/categories" class="waves-effect waves-light">
			
			    <i class="fa-fw fas fa-bookmark"></i>
			
			分类
		</a>
          
        </li>
        
        <li class="m-nav-item">
	  
		<a href="/archives" class="waves-effect waves-light">
			
			    <i class="fa-fw fas fa-archive"></i>
			
			归档
		</a>
          
        </li>
        
        <li class="m-nav-item">
	  
		<a href="javascript:;">
			
				<i class="fa-fw fas fa-list"></i>
			
			关于
			<span class="m-icon"><i class="fas fa-chevron-right"></i></span>
		</a>
            <ul style="background:  ;">
              
                <li>   
				
                  <a href="/about " style="margin-left:75px" ;>
				  
				   <i class="fa fas fa-user-circle" style="position: absolute;left:50px"></i>
			      
		          <span>简介</span>
                  </a>
                </li>
              
                <li>   
				
                  <a href="/team " style="margin-left:75px" ;>
				  
				   <i class="fa fas fa-user-circle" style="position: absolute;left:50px"></i>
			      
		          <span>团队</span>
                  </a>
                </li>
               
            </ul>
          
        </li>
        
        <li class="m-nav-item">
	  
		<a href="/friends" class="waves-effect waves-light">
			
			    <i class="fa-fw fas fa-address-book"></i>
			
			友情链接
		</a>
          
        </li>
        
        
        <li><div class="divider"></div></li>
        <li>
            <a href="https://github.com/508lab/" class="waves-effect waves-light" target="_blank">
                <i class="fab fa-github-square fa-fw"></i>Fork Me
            </a>
        </li>
        
    </ul>
</div>

        </div>

        
            <style>
    .nav-transparent .github-corner {
        display: none !important;
    }

    .github-corner {
        position: absolute;
        z-index: 10;
        top: 0;
        right: 0;
        border: 0;
        transform: scale(1.1);
    }

    .github-corner svg {
        color: #0f9d58;
        fill: #fff;
        height: 64px;
        width: 64px;
    }

    .github-corner:hover .octo-arm {
        animation: a 0.56s ease-in-out;
    }

    .github-corner .octo-arm {
        animation: none;
    }

    @keyframes a {
        0%,
        to {
            transform: rotate(0);
        }
        20%,
        60% {
            transform: rotate(-25deg);
        }
        40%,
        80% {
            transform: rotate(10deg);
        }
    }
</style>

<a href="https://github.com/508lab/" class="github-corner tooltipped hide-on-med-and-down" target="_blank" data-tooltip="Fork Me" data-position="left" data-delay="50">
    <svg viewbox="0 0 250 250" aria-hidden="true">
        <path d="M0,0 L115,115 L130,115 L142,142 L250,250 L250,0 Z"/>
        <path d="M128.3,109.0 C113.8,99.7 119.0,89.6 119.0,89.6 C122.0,82.7 120.5,78.6 120.5,78.6 C119.2,72.0 123.4,76.3 123.4,76.3 C127.3,80.9 125.5,87.3 125.5,87.3 C122.9,97.6 130.6,101.9 134.4,103.2" fill="currentColor" style="transform-origin: 130px 106px;" class="octo-arm"/>
        <path d="M115.0,115.0 C114.9,115.1 118.7,116.5 119.8,115.4 L133.7,101.6 C136.9,99.2 139.9,98.4 142.2,98.6 C133.8,88.0 127.5,74.4 143.8,58.0 C148.5,53.4 154.0,51.2 159.7,51.0 C160.3,49.4 163.2,43.6 171.4,40.1 C171.4,40.1 176.1,42.5 178.8,56.2 C183.1,58.6 187.2,61.8 190.9,65.4 C194.5,69.0 197.7,73.2 200.1,77.6 C213.8,80.2 216.3,84.9 216.3,84.9 C212.7,93.1 206.9,96.0 205.4,96.6 C205.1,102.4 203.0,107.8 198.3,112.5 C181.9,128.9 168.3,122.5 157.7,114.1 C157.9,116.9 156.7,120.9 152.7,124.9 L141.0,136.5 C139.8,137.7 141.6,141.9 141.8,141.8 Z" fill="currentColor" class="octo-body"/>
    </svg>
</a>
        
    </nav>

</header>

    
<script src="/libs/cryptojs/crypto-js.min.js"></script>
<script>
    (function() {
        let pwd = '';
        if (pwd && pwd.length > 0) {
            if (pwd !== CryptoJS.SHA256(prompt('请输入访问本文章的密码')).toString(CryptoJS.enc.Hex)) {
                alert('密码错误，将返回主页！');
                location.href = '/';
            }
        }
    })();
</script>




<div class="bg-cover pd-header post-cover" style="background-image: url('/medias/featureimages/19.jpg')">
    <div class="container" style="right: 0px;left: 0px;">
        <div class="row">
            <div class="col s12 m12 l12">
                <div class="brand">
                    <h1 class="description center-align post-title">AndroidStudio常用快捷键</h1>
                </div>
            </div>
        </div>
    </div>
</div>




<main class="post-container content">

    
    <link rel="stylesheet" href="/libs/tocbot/tocbot.css">
<style>
    #articleContent h1::before,
    #articleContent h2::before,
    #articleContent h3::before,
    #articleContent h4::before,
    #articleContent h5::before,
    #articleContent h6::before {
        display: block;
        content: " ";
        height: 100px;
        margin-top: -100px;
        visibility: hidden;
    }

    #articleContent :focus {
        outline: none;
    }

    .toc-fixed {
        position: fixed;
        top: 64px;
    }

    .toc-widget {
        width: 345px;
        padding-left: 20px;
    }

    .toc-widget .toc-title {
        margin: 35px 0 15px 0;
        padding-left: 17px;
        font-size: 1.5rem;
        font-weight: bold;
        line-height: 1.5rem;
    }

    .toc-widget ol {
        padding: 0;
        list-style: none;
    }

    #toc-content {
        height: calc(100vh - 250px);
        overflow: auto;
    }

    #toc-content ol {
        padding-left: 10px;
    }

    #toc-content ol li {
        padding-left: 10px;
    }

    #toc-content .toc-link:hover {
        color: #42b983;
        font-weight: 700;
        text-decoration: underline;
    }

    #toc-content .toc-link::before {
        background-color: transparent;
        max-height: 25px;
    }

    #toc-content .is-active-link {
        color: #42b983;
    }

    #toc-content .is-active-link::before {
        background-color: #42b983;
    }

    #floating-toc-btn {
        position: fixed;
        right: 15px;
        bottom: 76px;
        padding-top: 15px;
        margin-bottom: 0;
        z-index: 998;
    }

    #floating-toc-btn .btn-floating {
        width: 48px;
        height: 48px;
    }

    #floating-toc-btn .btn-floating i {
        line-height: 48px;
        font-size: 1.4rem;
    }
</style>
<div class="row">
    <div id="main-content" class="col s12 m12 l9">
        <!-- 文章内容详情 -->
<div id="artDetail">
    <div class="card">
        <div class="card-content article-info">
            <div class="row tag-cate">
                <div class="col s7">
                    
                    <div class="article-tag">
                        
                            <a href="/tags/Android/">
                                <span class="chip bg-color">Android</span>
                            </a>
                        
                    </div>
                    
                </div>
                <div class="col s5 right-align">
                    
                    <div class="post-cate">
                        <i class="fas fa-bookmark fa-fw icon-category"></i>
                        
                            <a href="/categories/工具/" class="post-category">
                                工具
                            </a>
                        
                    </div>
                    
                </div>
            </div>

            <div class="post-info">
                
                <div class="post-date info-break-policy">
                    <i class="far fa-calendar-minus fa-fw"></i>发布日期:&nbsp;&nbsp;
                    2016-09-30
                </div>
                

                

                

                
				
                
                    <div id="busuanzi_container_page_pv" class="info-break-policy">
                        <i class="far fa-eye fa-fw"></i>阅读次数:&nbsp;&nbsp;
                        <span id="busuanzi_value_page_pv"></span>
                    </div>
				
            </div>
            
        </div>
        <hr class="clearfix">
        <div class="card-content article-card-content">
            <div id="articleContent">
                <h3 id="常用的-Android-Studio-快捷键"><a href="#常用的-Android-Studio-快捷键" class="headerlink" title="常用的 Android Studio 快捷键:"></a>常用的 Android Studio 快捷键:</h3><p>以下是平时在Windwos系统上用Android Studio进行开发时常用到的一些快捷键，虽然不多，但是感觉都还蛮实用的，因此记录下来，如果什么时候不小心忘记了可以拿来翻一翻，That would be very useful！</p>
<blockquote>
<p>　　1.Ctrl + B</p>
</blockquote>
<p>　　跳入/跳出方法或者资源文件。将鼠标光标定位到某个方法或者资源id的调用处，按Ctrl + B，将会跳入该方法或者资源文件内部，功能等同于Ctrl + 鼠标左键。如果将鼠标光标定位到方法定义处或者资源文件内部，按Ctrl + B将会返回调用处。</p>
<blockquote>
<p>　　2.Ctrl + O</p>
</blockquote>
<p>　　查看父类中的方法， 并可以选择父类方法进行覆盖。将鼠标光标定位到类中代码的任意位置，按Ctrl + O，将会在打开的面板中查看到所有父类中的所有非私有方法，选择某个方法按Enter即可覆盖父类方法。</p>
<blockquote>
<p>　　3.Ctrl + K</p>
</blockquote>
<p>　　SVN提交代码。</p>
<blockquote>
<p>　　4.Ctrl + T</p>
</blockquote>
<p>　　SVN更新代码。</p>
<blockquote>
<p>　　5.Ctrl + H</p>
</blockquote>
<p>　　查看类的上下继承关系。将鼠标光标定位在类中的任何一个位置，然后按Ctrl + H，将会打开一个面板，在这个面板中会依照层级显示出当前类的所有父类和子类。</p>
<blockquote>
<p>　　6.Ctrl + W</p>
</blockquote>
<p>　　选中代码块。多次按Ctrl + W将逐步扩大选择范围。</p>
<blockquote>
<p>　　7.Ctrl + E</p>
</blockquote>
<p>　　显示最近打开的文件，可以快速再次打开这些文件。</p>
<blockquote>
<p>　　8.Ctrl + U</p>
</blockquote>
<p>　　快速跳转至父类，或者快速跳转到父类中的某个方法。将鼠标光标定位到类名上，按Ctrl +U，将会打开当前类的父类，如果当前类有多个父类，则会提示要打开的父类。如果一个类中的方法覆盖了其父类的方法，那么将鼠标光标定位到子类的方法，按Ctrl + U，将</p>
<p>会跳转到被覆盖的父类方法中。</p>
<blockquote>
<p>　　9.Ctrl + G</p>
</blockquote>
<p>　　显示鼠标光标当前位置在代码文件中的行/列数。可以理解为光标在代码中的横纵坐标。</p>
<blockquote>
<p>　　10.Ctrl + F12</p>
</blockquote>
<p>　　查看类中的所有变量、方法、内部类、内部接口。将鼠标光标定位到当前类文件的任意位置，按Ctrl + F12会弹出显示类中所有变量、方法、内部类、内部接口的对话框，然后按↑↓键可以选择某个变量、方法、内部类、内部接口，接着按Enter可以快速定位到该变</p>
<p>量、方法、内部类、内部接口。</p>
<blockquote>
<p>　　11.Ctrl + F11</p>
</blockquote>
<p>　　添加书签。在鼠标光标位置所在行添加书签。如果文件中的代码特别多，那么书签将是一个非常实用的功能，它可以帮助我们标记代码中的重要位置，方便我们下次快速定位到这些重要位置。</p>
<blockquote>
<p>　　12.Shift + F11</p>
</blockquote>
<p>　　查看书签。可以快速查看之前标记的书签。</p>
<blockquote>
<p>　　13.Ctrl + Shift + F12</p>
</blockquote>
<p>　　快速调整代码编辑窗口的大小。</p>
<blockquote>
<p>　　14.Ctrl + ↑↓</p>
</blockquote>
<p>　　固定光标上下移动代码。</p>
<blockquote>
<p>　　15.Alt + ↑↓</p>
</blockquote>
<p>　　在内部接口、内部类和方法之间跳转。</p>
<blockquote>
<p>　　16.Ctrl + Shift + Backspace</p>
</blockquote>
<p>　　回到上一次编辑的位置。</p>
<blockquote>
<p>　　17.Alt + 数字</p>
</blockquote>
<p>　　打开相应数字的面板。如终端控制台面板对应的数字是6，那么按Alt + 6可以快速展开或关闭控制台面板。</p>
<blockquote>
<p>　　18.Ctrl + Shift + I</p>
</blockquote>
<p>　　快速查看某个方法、类、接口的内容。将鼠标光标定位到某个方法、类名、接口名，然后按Ctrl + Shift + I，将会在当前光标位置显示改方法、类、接口的内容。</p>
<blockquote>
<p>　　19.Shift + Esc</p>
</blockquote>
<p>　　关闭当前打开的面板。</p>
<blockquote>
<p>　　20.Alt + J</p>
</blockquote>
<p>　　选择多个相同名字的关键字、方法、类、接口，然后同时更改。</p>
<blockquote>
<p>　　21.Ctrl + Tab</p>
</blockquote>
<p>　　切换面板或文件，功能类似Windows下的Alt + Tab。在切换面板/文件的对话框中，选中某个面板或文件，接着按Backspace即可关闭改面板或文件。</p>
<blockquote>
<p>　　22.trl + Shift + Enter</p>
</blockquote>
<p>　　快速补全语句。如if() {}、switch(){}代码块，只要输入if或者switch（甚至sw），接着按Ctrl + Shift + Enter可以快速完形代码块。</p>
<blockquote>
<p>　　23.Ctrl + Alt + M</p>
</blockquote>
<p>　　快速抽取方法。选中代码块，然后按Ctrl + Alt + M可以快速将选中的代码块抽取为一个方法。</p>
<blockquote>
<p>　　24.Ctrl + Alt + T </p>
</blockquote>
<p>　　快速包裹代码块。选中一段代码，然后按Ctrl + Alt + T，可以选择要对选中代码块进行的操作，如：if / else、do / while、try / catch / finally等。</p>
<blockquote>
<p>　　25.Ctrl  + Alt + L</p>
</blockquote>
<p>　　代码格式化。</p>
<blockquote>
<p>　　26.Ctrl + N</p>
</blockquote>
<p>　　快速查找类。按下Ctrl + N会弹出输入类名的对话框，在对话框的搜索框中输入要查找的类名，即可开始进行模糊检索，这样可以快速找到需要查找的类，这在类文件非常多的工程里面特别实用。</p>
<blockquote>
<p>　　27.Ctrl + Shift + N</p>
</blockquote>
<p>　　快速查找文件。功能和Ctrl + N类似，但是除了可以搜索类文件之外，还可以搜索当前工程下的所有文件，这同样是一个经常用到的特别实用的功能。</p>
<blockquote>
<p>　　28.Double Shift</p>
</blockquote>
<p>　　全局搜索。功能和Ctrl + N、Ctrl + Shift + N类似，但是搜索的范围更广，支持符号检索，除了Ctrl + N、Ctrl + Shift + N的检索内容外，还可以搜索到变量、资源id等。</p>
<blockquote>
<p>　　29.Ctrl + Alt + Space</p>
</blockquote>
<p>　　类名或接口名提示。输入一个不完整的类名或者接口名，按Ctrl + Alt + Space，会给出完整类名或接口名的提示。</p>
<blockquote>
<p>　　30.Ctrl  + Q</p>
</blockquote>
<p>　　显示注释文档。将鼠标光标定位到某个类名、接口名或者方法名，按Ctrl + Q，会显示出该类、接口、方法的注释。</p>
<blockquote>
<p>　　31.Ctrl + PageUp/PageDown</p>
</blockquote>
<p>　　将光标定位到当前文件的第一行/最后一行。</p>
<blockquote>
<p>　　32.Shift + Left Click（当前文件的选项卡）</p>
</blockquote>
<p>　　关闭当前文件。</p>
<blockquote>
<p>　　33.Ctrl + Alt + B　　</p>
</blockquote>
<p>　　跳转到抽象方法的实现。将鼠标光标定位到某个抽象方法，然后按Ctrl + Alt + B，会快速跳转到该抽象方法的具体实现处，如果该抽象方法有多个具体实现，那么会弹出选择框进行选择。</p>
<blockquote>
<p>　　34.Ctrl + Shift + U </p>
</blockquote>
<p>　　快速进行大小写转换。</p>
<blockquote>
<p>　　35.Ctrl + Shift + Alt + S</p>
</blockquote>
<p>　　打开Project Structure面板。</p>
<blockquote>
<p>　　36.Ctrl + F</p>
</blockquote>
<p>　　在当前文件中搜索输入的内容。</p>
<blockquote>
<p>　　37.Ctrl + R</p>
</blockquote>
<p>　　在当前文件中替换输入的内容。</p>
<blockquote>
<p>　　38.Ctrl + Shift + F</p>
</blockquote>
<p>　　全局搜索。</p>
<blockquote>
<p>　　39.Ctrl + Shift + R</p>
</blockquote>
<p>　　全局替换。</p>
<blockquote>
<p>　　40.Shift + F6</p>
</blockquote>
<p>　　快速重命名。选中某个类、变量、资源id等之后，可以快速重命名，只要改动一个位置，其它地方也都会自动全部重命名。</p>
<blockquote>
<p>　　41.Alt + F7</p>
</blockquote>
<p>　　快速查找某个类、方法、变量、资源id被调用的地方。</p>
<blockquote>
<p>　　42.Ctrl +Shift + Alt + I</p>
</blockquote>
<p>　　对项目进行审查。按下Ctrl +Shift + Alt + I，会弹出搜索审查项的输入框，输入关键字可以检索需要审查的内容，例如输入unused resource即可搜索项目中没有使用到的资源文件。此外，在菜单栏选择Analyze—Inspect Code或者鼠标右键点击当前工程— 　Analyze—Inspect Code，可以对项目进行Lint审查。</p>
<blockquote>
<p>　　43.Ctrl + D</p>
</blockquote>
<p>　　快速复制行。</p>
<blockquote>
<p>　　44.Ctrl + Shift + ↑↓</p>
</blockquote>
<p>　　上下移动代码。如果是方法中的代码，只能在方法内部一定，不能跨方法。</p>
<blockquote>
<p>　　45.Shift + Alt + ↑↓</p>
</blockquote>
<p>　　上下移动代码。可以跨方法移动。</p>
<blockquote>
<p>　　46.Shift + F10</p>
</blockquote>
<p>　　启动Module。</p>
<blockquote>
<p>　　47.Shift + F9</p>
</blockquote>
<p>　　调试Module。</p>
<blockquote>
<p>　　48.Ctrl + F9</p>
</blockquote>
<p>　　Make Project。</p>
<blockquote>
<p>　　49.Alt + Insert</p>
</blockquote>
<p>　　快速插入代码。可以快速生成构造方法、Getter/Setter方法等。</p>
<blockquote>
<p>　　50.Alt + Enter</p>
</blockquote>
<p>　　快速修复错误。</p>
<p align="right">编写：栗郑辉</p>
            </div>
            <hr>

            



            <div class="tag_share" style="display: block;">
                <div class="post-meta__tag-list" style="display: inline-block;">
                    
                        <div class="article-tag">
                            
                                <a href="/tags/Android/">
                                    <span class="chip bg-color">Android</span>
                                </a>
                            
                        </div>
                    
                </div>
                <div class="post_share" style="zoom: 80%; width: fit-content; display: inline-block; float: right; margin: -0.15rem 0;">
                    <link rel="stylesheet" type="text/css" href="/libs/share/css/share.min.css">

<div id="article-share">
    
    
    <div class="social-share" data-sites="twitter,facebook,google,qq,qzone,wechat,weibo,douban,linkedin" data-wechat-qrcode-helper="<p>微信扫一扫即可分享！</p>"></div>
    <script src="/libs/share/js/social-share.min.js"></script>
    

    

</div>

                </div>
            </div>
            
        </div>
    </div>

    
        <link rel="stylesheet" href="/libs/gitalk/gitalk.css">
<link rel="stylesheet" href="/css/my-gitalk.css">

<div class="card gitalk-card" data-aos="fade-up">
    <div class="comment_headling" style="font-size: 20px; font-weight: 700; position: relative; left: 20px; top: 15px; padding-bottom: 5px;">
        <i class="fas fa-comments fa-fw" aria-hidden="true"></i>
        <span>评论</span>
    </div>
    <div id="gitalk-container" class="card-content"></div>
</div>

<script src="/libs/gitalk/gitalk.min.js"></script>
<script>
    let gitalk = new Gitalk({
        clientID: 'a7796bec1c5d19f98482',
        clientSecret: '09bbf2bb0bed2ab1ad80b58786db4a785eb99de6',
        repo: '508lab.github.io',
        owner: '508lab',
        admin: ["schizobulia"],
        id: '2016-09-30T18-15-06',
        distractionFreeMode: false  // Facebook-like distraction free mode
    });

    gitalk.render('gitalk-container');
</script>
    

    

    

    

    

    

<article id="prenext-posts" class="prev-next articles">
    <div class="row article-row">
        
        <div class="article col s12 m6" data-aos="fade-up">
            <div class="article-badge left-badge text-color">
                <i class="fas fa-chevron-left"></i>&nbsp;上一篇</div>
            <div class="card">
                <a href="/2019/05/08/da-shu-ju/zui-xin-ban-elasticsearch-mian-fei-jia-mi/">
                    <div class="card-image">
                        
                        
                        <img src="/medias/featureimages/1.jpg" class="responsive-img" alt="最新版ElasticSearch免费加密">
                        
                        <span class="card-title">最新版ElasticSearch免费加密</span>
                    </div>
                </a>
                <div class="card-content article-content">
                    <div class="summary block-with-text">
                        
                            新版本官方介绍7.0之后的版本免费加密比较稳定,之前的版本还是建议使用Search Guard快速加密去除部分步骤    1. ./bin/elasticsearch-certutil cert -out config/elastic-ce
                        
                    </div>
                    <div class="publish-info">
                        <span class="publish-date">
                            <i class="far fa-clock fa-fw icon-date"></i>2019-05-08
                        </span>
                        <span class="publish-author">
                            
                            <i class="fas fa-bookmark fa-fw icon-category"></i>
                            
                            <a href="/categories/大数据/" class="post-category">
                                    大数据
                                </a>
                            
                            
                        </span>
                    </div>
                </div>
                
                <div class="card-action article-tags">
                    
                    <a href="/tags/ELK/">
                        <span class="chip bg-color">ELK</span>
                    </a>
                    
                    <a href="/tags/大数据/">
                        <span class="chip bg-color">大数据</span>
                    </a>
                    
                    <a href="/tags/Search-Guard/">
                        <span class="chip bg-color">Search-Guard</span>
                    </a>
                    
                </div>
                
            </div>
        </div>
        
        
        <div class="article col s12 m6" data-aos="fade-up">
            <div class="article-badge right-badge text-color">
                下一篇&nbsp;<i class="fas fa-chevron-right"></i>
            </div>
            <div class="card">
                <a href="/2016/09/27/android/activity/">
                    <div class="card-image">
                        
                        
                        <img src="/medias/featureimages/20.jpg" class="responsive-img" alt="Activity生命周期">
                        
                        <span class="card-title">Activity生命周期</span>
                    </div>
                </a>
                <div class="card-content article-content">
                    <div class="summary block-with-text">
                        
                            Activity恐怕是Android用得最多且是最基本的组件了，估计也是每个学Android的人接触的第一概念，Activity的生命周期与启动模式是作为一个Android开发程序员必要掌握内容 ， 还希望本篇文章对您有所帮助。
Activ
                        
                    </div>
                    <div class="publish-info">
                            <span class="publish-date">
                                <i class="far fa-clock fa-fw icon-date"></i>2016-09-27
                            </span>
                        <span class="publish-author">
                            
                            <i class="fas fa-bookmark fa-fw icon-category"></i>
                            
                            <a href="/categories/Android/" class="post-category">
                                    Android
                                </a>
                            
                            
                        </span>
                    </div>
                </div>
                
                <div class="card-action article-tags">
                    
                    <a href="/tags/Android/">
                        <span class="chip bg-color">Android</span>
                    </a>
                    
                </div>
                
            </div>
        </div>
        
    </div>
</article>

</div>



<!-- 代码块功能依赖 -->
<script type="text/javascript" src="/libs/codeBlock/codeBlockFuction.js"></script>

<!-- 代码语言 -->

<script type="text/javascript" src="/libs/codeBlock/codeLang.js"></script>

    
<!-- 代码块复制 -->

<script type="text/javascript" src="/libs/codeBlock/codeCopy.js"></script>


<!-- 代码块收缩 -->

<script type="text/javascript" src="/libs/codeBlock/codeShrink.js"></script>


<!-- 代码块折行 -->

<style type="text/css">
code[class*="language-"], pre[class*="language-"] { white-space: pre !important; }
</style>

    </div>
    <div id="toc-aside" class="expanded col l3 hide-on-med-and-down">
        <div class="toc-widget">
            <div class="toc-title"><i class="far fa-list-alt"></i>&nbsp;&nbsp;目录</div>
            <div id="toc-content"></div>
        </div>
    </div>
</div>

<!-- TOC 悬浮按钮. -->

<div id="floating-toc-btn" class="hide-on-med-and-down">
    <a class="btn-floating btn-large bg-color">
        <i class="fas fa-list-ul"></i>
    </a>
</div>


<script src="/libs/tocbot/tocbot.min.js"></script>
<script>
    $(function () {
        tocbot.init({
            tocSelector: '#toc-content',
            contentSelector: '#articleContent',
            headingsOffset: -($(window).height() * 0.4 - 45),
            collapseDepth: Number('0'),
            headingSelector: 'h2, h3, h4'
        });

        // modify the toc link href to support Chinese.
        let i = 0;
        let tocHeading = 'toc-heading-';
        $('#toc-content a').each(function () {
            $(this).attr('href', '#' + tocHeading + (++i));
        });

        // modify the heading title id to support Chinese.
        i = 0;
        $('#articleContent').children('h2, h3, h4').each(function () {
            $(this).attr('id', tocHeading + (++i));
        });

        // Set scroll toc fixed.
        let tocHeight = parseInt($(window).height() * 0.4 - 64);
        let $tocWidget = $('.toc-widget');
        $(window).scroll(function () {
            let scroll = $(window).scrollTop();
            /* add post toc fixed. */
            if (scroll > tocHeight) {
                $tocWidget.addClass('toc-fixed');
            } else {
                $tocWidget.removeClass('toc-fixed');
            }
        });

        
        /* 修复文章卡片 div 的宽度. */
        let fixPostCardWidth = function (srcId, targetId) {
            let srcDiv = $('#' + srcId);
            if (srcDiv.length === 0) {
                return;
            }

            let w = srcDiv.width();
            if (w >= 450) {
                w = w + 21;
            } else if (w >= 350 && w < 450) {
                w = w + 18;
            } else if (w >= 300 && w < 350) {
                w = w + 16;
            } else {
                w = w + 14;
            }
            $('#' + targetId).width(w);
        };

        // 切换TOC目录展开收缩的相关操作.
        const expandedClass = 'expanded';
        let $tocAside = $('#toc-aside');
        let $mainContent = $('#main-content');
        $('#floating-toc-btn .btn-floating').click(function () {
            if ($tocAside.hasClass(expandedClass)) {
                $tocAside.removeClass(expandedClass).hide();
                $mainContent.removeClass('l9');
            } else {
                $tocAside.addClass(expandedClass).show();
                $mainContent.addClass('l9');
            }
            fixPostCardWidth('artDetail', 'prenext-posts');
        });
        
    });
</script>

    

</main>



    <footer class="page-footer bg-color">
    <div class="container row center-align" style="margin-bottom: 0px !important;">
        <div class="col s12 m8 l8 copy-right">
            Copyright&nbsp;&copy;
            <span id="year">2019</span>
            <a href="https://508lab.github.io" target="_blank">508工作室</a>
            |&nbsp;Powered by&nbsp;<a href="https://hexo.io/" target="_blank">Hexo</a>
            |&nbsp;Theme&nbsp;<a href="https://github.com/blinkfox/hexo-theme-matery" target="_blank">Matery</a>
            <br>
            
            
            
            
            
            
            <span id="busuanzi_container_site_pv">
                |&nbsp;<i class="far fa-eye"></i>&nbsp;总访问量:&nbsp;<span id="busuanzi_value_site_pv" class="white-color"></span>&nbsp;次
            </span>
            
            
            <span id="busuanzi_container_site_uv">
                |&nbsp;<i class="fas fa-users"></i>&nbsp;总访问人数:&nbsp;<span id="busuanzi_value_site_uv" class="white-color"></span>&nbsp;人
            </span>
            
            <br>
            
            <br>
            
        </div>
        <div class="col s12 m4 l4 social-link social-statis">
    <a href="https://github.com/508lab" class="tooltipped" target="_blank" data-tooltip="访问我的GitHub" data-position="top" data-delay="50">
        <i class="fab fa-github"></i>
    </a>



    <a href="mailto:2833324528@qq.com" class="tooltipped" target="_blank" data-tooltip="邮件联系我" data-position="top" data-delay="50">
        <i class="fas fa-envelope-open"></i>
    </a>







    <a href="tencent://AddContact/?fromId=50&fromSubId=1&subcmd=all&uin=2833324528" class="tooltipped" target="_blank" data-tooltip="QQ联系我: 2833324528" data-position="top" data-delay="50">
        <i class="fab fa-qq"></i>
    </a>







</div>
    </div>
</footer>

<div class="progress-bar"></div>


    <!-- 搜索遮罩框 -->
<div id="searchModal" class="modal">
    <div class="modal-content">
        <div class="search-header">
            <span class="title"><i class="fas fa-search"></i>&nbsp;&nbsp;搜索</span>
            <input type="search" id="searchInput" name="s" placeholder="请输入搜索的关键字" class="search-input">
        </div>
        <div id="searchResult"></div>
    </div>
</div>

<script src="/js/search.js"></script>
<script type="text/javascript">
$(function () {
    searchFunc("/" + "search.xml", 'searchInput', 'searchResult');
});
</script>
    <!-- 回到顶部按钮 -->
<div id="backTop" class="top-scroll">
    <a class="btn-floating btn-large waves-effect waves-light" href="#!">
        <i class="fas fa-arrow-up"></i>
    </a>
</div>


    <script src="/libs/materialize/materialize.min.js"></script>
    <script src="/libs/masonry/masonry.pkgd.min.js"></script>
    <script src="/libs/aos/aos.js"></script>
    <script src="/libs/scrollprogress/scrollProgress.min.js"></script>
    <script src="/libs/lightGallery/js/lightgallery-all.min.js"></script>
    <script src="/js/matery.js"></script>

    <!-- Global site tag (gtag.js) - Google Analytics -->


    <!-- Baidu Analytics -->

    <!-- Baidu Push -->

<script>
    (function () {
        var bp = document.createElement('script');
        var curProtocol = window.location.protocol.split(':')[0];
        if (curProtocol === 'https') {
            bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';
        } else {
            bp.src = 'http://push.zhanzhang.baidu.com/push.js';
        }
        var s = document.getElementsByTagName("script")[0];
        s.parentNode.insertBefore(bp, s);
    })();
</script>

    
    <script src="/libs/others/clicklove.js" async="async"></script>
    
    
    <script async src="/libs/others/busuanzi.pure.mini.js"></script>
    

    

    

    

    

    
    
    
    <script src="/libs/instantpage/instantpage.js" type="module"></script>
    

</body>

</html>
